//package nancal.mp.mvc.devops
//
//import nancal.mp.db.mongo.mor
//import nbcp.bean.FlywayBeanProcessor
//import nbcp.base.comm.JsonResult
//
//import nbcp.myoql.db.mongo.delete
//import nbcp.myoql.db.mongo.query
//import nbcp.base.utils.*
//import org.springframework.web.bind.annotation.RequestMapping

//import org.springframework.web.bind.annotation.RequestMethod

//import org.springframework.web.bind.annotation.RestController

//
//@RestController
//@OpenAction
//@RequestMapping("/ops/flyway")
//class FlywayController {
//
//    @RequestMapping("/replay", method = arrayOf(RequestMethod.POST, RequestMethod.GET))
//    fun replay(): JsonResult {
//        mor.base.sysFlywayVersion.delete()
//            .where { it.version mongoNotEquals 0 }
//            .exec();
//
//        val flyways = SpringUtil.getBeanWithNull(FlywayBeanProcessor::class.java)
//        if (flyways != null) {
//            flyways.playFlyVersion();
//        }
//
//        return JsonResult()
//    }
//}